package com.kaduoxee.ebooks.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.kaduoxee.ebooks.entity.Chapter;
import org.apache.ibatis.annotations.Select;

public interface ChapterMapper extends BaseMapper<Chapter> {

    /**
     *
     * @param fictionId 小说id
     * @return fiction最新章节对应的sort
     */
    @Select("select max(sort) from ebooks.chapter where fiction_id = #{fictionId} ")
    Integer fictionMS (Integer fictionId);
}
